package top.fullj.remoting;

import top.fullj.remoting.consumer.ConnectionPool;
import top.fullj.remoting.consumer.Stub;

/**
 * @author bruce.wu
 * @since 2022/2/14 10:32
 */
public class ClientApp {

    public static void main(String[] args) {
        try {
            HelloService helloService = Stub.create(HelloService.class);
            System.out.println(helloService.sayHello());
            System.out.println(helloService.sayHello("world"));
            System.out.println(helloService.sayHello(null));
            System.out.println(helloService.sayHello("world", 1));
        } finally {
            ConnectionPool.getInstance().release();
        }
    }

}
